import { Draw } from "../../../Draw/Draw";
import { setStageCursor } from "./stage-cursor";

/**
 * Konva Graph 基类鼠标离开事件处理函数
 * @param draw
 */
export function groupMouseLeave(draw: Draw) {
  // 如果处于插入状态
  const stage = draw.getStage();
  if (stage.getAttr("insertShape")) setStageCursor(draw, "crosshair");
  else setStageCursor(draw, "default");
}
